package com.shi.yibanjia.controller;

import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RestController;

import java.io.File;

@RestController
public class TestController {

    @GetMapping("/admin/test/upload")
    public String testFilePath() {
        String absolutePath = new File("file/upload/").getAbsolutePath();
        File file = new File(absolutePath);
        if (!file.exists()) {
            file.mkdirs();
        }
        return absolutePath;
    }
}
